package pojo;

import org.w3c.dom.Document;
import org.w3c.dom.Element;

public class CayThaoLuanPOJO {
	private int id;
	private long version;
	private String noiDung;
	private int idNhom;
	private int idNguoiTao;
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public long getVersion() {
		return version;
	}
	public void setVersion(long version) {
		this.version = version;
	}
	public String getNoiDung() {
		return noiDung;
	}
	public void setNoiDung(String noiDung) {
		this.noiDung = noiDung;
	}
	public int getIdNhom() {
		return idNhom;
	}
	public void setIdNhom(int idNhom) {
		this.idNhom = idNhom;
	}
	public int getIdNguoiTao() {
		return idNguoiTao;
	}
	public void setIdNguoiTao(int idNguoiTao) {
		this.idNguoiTao = idNguoiTao;
	}
	
	public Element createXMLElement(Document doc){
		Element e=doc.createElement("Cay");
		e.setAttribute("ID", this.id+"");
		e.setAttribute("version", this.version+"");
		e.setAttribute("NoiDung", this.noiDung);
		e.setAttribute("IDNhom", this.idNhom+"");
		e.setAttribute("IDNguoiTao", this.idNguoiTao+"");
		return e;
	}
	
}
